home *** CD-ROM | disk | FTP | other *** search
/ Games of Daze / Infomagic - Games of Daze (Summer 1995) (Disc 1 of 2).iso / x2ftp / msdos / libs / pdcurs21 / private / _scrnmod.c < prev    next >
C/C++ Source or Header  |  1993-06-18  |  1KB  |  50 lines

  1. #define    CURSES_LIBRARY    1
  2. #include <curses.h>
  3.  
  4. #ifdef PDCDEBUG
  5. char *rcsid__scrnmod = "$Header: C:\CURSES\private\RCS\_scrnmod.c 2.1 1993/06/18 20:22:52 MH Rel MH $";
  6. #endif
  7.  
  8.  
  9.  
  10. /*man-start*********************************************************************
  11.  
  12.   PDC_scrn_modes_equal()    - Decide if two screen modes are equal
  13.  
  14.   PDCurses Description:
  15.      Mainly required for OS/2. It decides if two screen modes
  16.         (VIOMODEINFO structure) are equal. Under DOS it just compares
  17.         two integers
  18.  
  19.   PDCurses Return Value:
  20.      This function returns TRUE if equal else FALSe.
  21.  
  22.   PDCurses Errors:
  23.      No errors are defined for this function.
  24.  
  25.   Portability:
  26.      PDCurses    int PDC_scrn_modes_equal( int mode1, int mode2 );
  27.      OS2 PDCurses    int PDC_scrn_modes_equal( VIOMODEINFO mode1, VIOMODEINFO mode2 );
  28.  
  29. **man-end**********************************************************************/
  30.  
  31. #ifdef     OS2
  32. bool    PDC_scrn_modes_equal(VIOMODEINFO mode1, VIOMODEINFO mode2)
  33. #else
  34. bool    PDC_scrn_modes_equal(int mode1, int mode2)
  35. #endif
  36. {
  37. #ifdef PDCDEBUG
  38.     if (trace_on) PDC_debug("PDC_scrn_modes_equal() - called\n");
  39. #endif
  40.  
  41. #ifdef     OS2
  42.     return (   (mode1.cb == mode2.cb) && (mode1.fbType == mode2.fbType)
  43.             && (mode1.color == mode2.color) && (mode1.col == mode2.col)
  44.             && (mode1.row == mode2.row) && (mode1.hres == mode2.vres)
  45.             && (mode1.vres == mode2.vres) );
  46. #else
  47.     return (mode1 == mode2);
  48. #endif
  49. }
  50.